



extern char my_host_byte_order;
extern char my_host_osbits;


extern short	plded_yc_keyId_field_no;//98.10.22
extern short	pld_yc_keyid_field_no;	//98.10.22
extern int	current_pld_num; 	//98.10.22
extern struct pld_result_struct pld_info_buf[]; //98.10.22

extern int     current_yc_sample_num;//98.10.14
//extern int     current_yx_sample_num;//98.10.14
extern int     current_dd_sample_num;//98.10.14

extern int	run_tag;
extern time_t	last_sample_time;
extern int g_sample_interval;

extern int	real_yc_sample_table_num;
extern int	hist_yc_sample_table_num;
//extern int	real_yx_sample_table_num;
//extern int	hist_yx_sample_table_num;
extern int	hist_dd_sample_table_num;
extern int	yc_current_total_fields_num;
//extern int	yx_current_total_fields_num;
extern int	dd_current_total_fields_num;
extern class 	system_net_info  history_sample;

extern struct	one_sybase_info	yc_rsam_table_info[];
extern struct	one_yc_real_commit_info *yc_rsam_value;
extern int 	yc_real_record_num;
extern struct	one_sybase_info	yc_hsam_table_info[];
//extern struct	one_sybase_info	yx_rsam_table_info[];
//extern struct	one_sybase_info	yx_hsam_table_info[];
extern struct	one_sybase_info	dd_hsam_table_info[];
extern struct	yc_sample_info	*yc_sam_field_info;
//extern struct	yx_sample_info	*yx_sam_field_info; 
extern struct	dd_sample_info	*dd_sam_field_info; 

// Added by ZJH in SZB 02.01.22 for 1 + N problem
// global var indicates the status of current machine (whether is front machine and whether is main or backup)
extern int     front_machine_status;
extern int      need_save_to_file;
extern int      commit_number;
extern char     sql_file_name[50];
// End of Added

extern class one_second_sample_class	one_secod_sample;//2000.05.06
extern class sql_sentence_buf_obj SQL_sentence;	//2000.05.02

extern int read_yc_sample_define_table();
//extern int read_yx_sample_define_table();
extern int read_dd_sample_define_table();
extern int init_sybase(class system_net_info &sys_info);
//extern int execute_yx_sample(time_t cur_t);
extern int execute_yc_sample(time_t cur_t);
extern int execute_dd_sample(time_t cur_t);
extern int execute_sql_sentence(char *sql_sentence);
extern int execute_sql_sentence6(char *sql_sentence);
extern int init_pld_info(); //98.10.22
extern int read_pld_info(); //98.10.22

// Added by ZJH in SZB  02.01.23 for 1 + N problem
extern int      save_sql_to_file(
        char    *sql_file_name,
        char    *sql_sentence);
// End of Added

extern YcChangeList g_YcChangeList;
extern YcSampleList g_YcSampleList;
extern SgTimeList g_SgTimeList;
extern YcChangeList g_YcRealCurveList;

extern int g_SgBeforeTime;
extern int g_SgAfterTime;

extern int g_RealCurveBeforeTime;




